/*
 * GaseousActivity.h
 *
 *  Created on: 20 Aug 2011
 *      Author: Allan
 */

#ifndef GASEOUSACTIVITY_H_
#define GASEOUSACTIVITY_H_

// C++ includes
#include <string>
#include <vector>
using namespace std;

// GeoReact includes
#include <Core/Activity.h>
#include <Utils/Types.h>

class GaseousActivity : public Activity
{
public:
	GaseousActivity();
	
	GaseousActivity(const string& species, const vector<string>& phase_species, const ActivityCoefficientFunction& activity_coefficient);
	
	virtual ~GaseousActivity();

	virtual const double activity(double T, double P, const VectorXd& n) const;
	
	virtual const double activityCoefficient(double T, double P, const VectorXd& n) const;
	
	virtual const VectorXd activityDerivatives(double T, double P, const VectorXd& n, const VectorXd& a) const;
	
protected:
	/// The index of the species in the gaseous solution for which the activity is being defined
	Index index_species;
	
	/// The activity coefficient function
	ActivityCoefficientFunction activity_coefficient;
};

const GaseousActivity GaseousActivityIdealModel(const string& species, const vector<string>& phase_species);

const GaseousActivity GaseousActivitySpycherReedCO2Model(const vector<string>& phase_species);

const GaseousActivity GaseousActivitySpycherReedH2OModel(const vector<string>& phase_species);

#endif /* GASEOUSACTIVITY_H_ */
